home *** CD-ROM | disk | FTP | other *** search
/ Aminet 7 / Aminet 7 - August 1995.iso / Aminet / comm / mebbs / younggns.lha / YG.rexx < prev   
OS/2 REXX Batch file  |  1995-02-06  |  62KB  |  2,511 lines

  1. /*  -=-=- Young Guns -=-=-
  2.   MEBBSNet Conversion BY:
  3.      Gene Wilber          */
  4.  
  5. SIGNAL ON ERROR
  6. SIGNAL ON SYNTAX
  7. SIGNAL ON IOERR
  8. SIGNAL ON FAILURE
  9.  
  10. parse arg ln
  11. options results
  12.  
  13. Doorname = "Young Guns"
  14. BBS = "Midnight Rodeo"           /* Place your BBS name here. */
  15. Mainpath = "Doors:YoungGuns/"
  16. Author = "Gene Wilber"
  17. Ver = "Mebbsnet V1.0"
  18.  
  19. if( ~show( 'l', "mebbsarexx.library" ) )then do
  20.  if( ~addlib( "mebbsarexx.library", 0, -30, 0 ) )then do
  21.   say "Could not open library"
  22.   exit 10
  23.  end
  24. end
  25.  
  26. call time 'R'
  27.  
  28. call GetVar dn,ln, 1
  29. username = result
  30. time = result
  31. inuseuser = ""
  32. inuseline = 0
  33.  
  34. if exists(Mainpath"INUSE.TXT") then do
  35.  call open(file,Mainpath"INUSE.TXT",'R')
  36.  inuseuser = readln(file)
  37.  inuseline = readln(file)
  38.  call close(file)
  39.  if inuseline=~ln then do
  40.   call Bl
  41.   str = CLS "Young Guns is currently in use by "inuseuser" on line "inuseline"."
  42.   call Out
  43.   str = "Please try back in a little while..."
  44.   call Out
  45.   call Bl
  46.   call Returnc
  47.   call ENDIT
  48.  end
  49. end
  50.  
  51. call open(file,Mainpath"INUSE.TXT",'W')
  52.  call writeln(file, username)
  53.  call writeln(file,ln)
  54.  call close file
  55.  
  56. CLS = 'H'
  57. BLK = ''
  58. RED = ''
  59. GRN = ''
  60. YEL = ''
  61. BLU = ''
  62. PUR = ''
  63. CYA = ''
  64. WHT = ''
  65. OFF = ''
  66. BLUYEL = ''
  67. CYAWHT = ''
  68. CyaBlu = ''
  69. BluCya = ''
  70. BluWht = ''
  71. BluPur = ''
  72. CyaPur = ''
  73. GrnYel = ''
  74. RedYel = ''
  75.  
  76. gun = 'Old Pistol'
  77. wins = 0
  78. lost = 0
  79. level = 0
  80. bullets = 50
  81. exp = 0
  82. money = 200
  83. bankmon = 0
  84. hits = 50
  85. med = 10
  86. expan = 0
  87. levl = 0
  88. levw = 0
  89. startmins = time('M')
  90. ha = 0
  91. l = 0
  92.  
  93. str = cls||'                     '||Blu||'___    ___'||Off
  94. call Out
  95. str = '                    '||Cya||'/'||Yel||'\  \  /  /'||Off
  96. call Out
  97. str = '                    '||Cya||'\ '||Yel||'\  \'||Yel||'/  /'||Off                          
  98. call Out
  99. str = '                     '||Cya||'\ '||Yel||'\    /'||Off||''||Blu||'___  ___  _____   __  _____'||Off
  100. call Out
  101. str = '                      '||Cya||'\|'||Yel||'|  |    \|  | |  |  \ |  ||  _  |'||Off   
  102. call Out
  103. str = '                       '||Cya||'|'||Yel||'|  | -   |  |_|  |   \|  || |_| |'||Off
  104. call Out
  105. str = '                       '||Cya||'|'||Yel||'|__|____/|_______|__|\___||___  |'||Off
  106. call Out
  107. str = '                       '||Cya||'|/_//___/ /______//_/ /__/ __|'||Yel||'_| |'||Off
  108. call Out
  109. str = '                                                 '||Cya||'|_'||Yel||'|____|'||Off
  110. call Out
  111. str = ''
  112. call Out
  113. str =  '                            '||Cya||'+---+ +   + +  + +---+'||Off
  114. call Out
  115. str = '                            '||Cya||'|     |   | |\ | |'||Off
  116. call Out
  117. str = '                            '||Cya||'| --+ |   | | \| +---+'||Off    
  118. call Out
  119. str = '                            '||Cya||'|   | |   | |  |     |'||Off
  120. call Out
  121. str = '                            '||Cya||'+---+ +---+ +  + +---+'||Off
  122. call Out
  123. str = '                    '||BluYel||' MEBBSNet Conversion by Gene Wilber '||Off
  124. call Out
  125. str = '                    '||BluYel||' Midnight Rodeo BBS (414)855-6399   '||Off
  126. call Out
  127. str = '                    '||BluYel||' Original Idea By Eddie Edwards     '||Off
  128. call Out
  129. call Bl
  130. str = 'Hit [RETURN]'
  131. call GetKey
  132. answer = upper(hot)
  133. str = CLS
  134. call Out
  135.  
  136. if exists('DOORS:YoungGuns/LastPlayer') then do
  137. call open(file,'DOORS:YoungGuns/LastPlayer',"R")
  138. last = readln(file);call close(file);end
  139. if ~exists('DOORS:YoungGuns/LastPlayer') then last = 'No One'
  140. if ~exists('DOORS:YoungGuns/Pistolers/'username'') then signal New
  141. signal old
  142.  
  143. New:
  144. str = Cya 'Ah... A new player!'Off
  145. call Out
  146.  
  147. Alias:
  148. str = Yel'Would you like to use an alias?['||Blu||'y'||YEL||'/N]'Off
  149. call GetKey
  150. ans = upper(hot)
  151. str = ''
  152. call Out
  153. if ans = 'Y' then do
  154. str = Blu'             >--------------<' Off
  155. call Out
  156. str = Cya 'Enter alias >'Off
  157. length = 15
  158. call Input
  159. Alias = upper(typed)
  160. if compress(alias) = '' then signal Alias
  161. if length(alias) > 15 then signal Alias
  162. end
  163. else Alias = username
  164. if exists('DOORS:YoungGuns/Players') then do
  165. call open(file,'DOORS:YoungGuns/Players',"A")
  166. call writeln file, username':'alias;call close(file);end
  167. if ~exists('DOORS:YoungGuns/Players') then do
  168. call open(file,'DOORS:YoungGuns/Players',"W")
  169. call writeln file, username':'alias;call close(file);end
  170. call open(file,'DOORS:YoungGuns/Pistolers/'username'',"W")
  171. call writeln file, gun;call writeln file, bullets;call writeln file, wins
  172. call writeln file, lost;call writeln file, level;call writeln file, exp
  173. call writeln file, money;call writeln file, bankmon;call writeln file, hits
  174. call writeln file, med;call writeln file, alias
  175. call close(file)
  176. str = Blu'You''re all set!  Enjoy the game.'Off
  177. call Out
  178. signal load;end
  179.  
  180.  
  181. Old:
  182. str = Yel'Welcome back and good luck!'Off
  183. call Out
  184. str = Blu'The last person to play Young Guns was - '||CYA||''last'. 'Off
  185. call Out
  186. Mailcheck:
  187. if ~exists('DOORS:YoungGuns/Mail/'alias'') then do
  188. str = Cya'You were lucky, no one attacked you since you last played.'Off
  189. call Out
  190. end
  191. if exists('DOORS:YoungGuns/Mail/'alias'') then do
  192. sendfile 'DOORS:YoungGuns/Mail/'alias''
  193. address command 'c:delete DOORS:YoungGuns/Mail/'alias''
  194. end
  195.  
  196. Start:
  197. call open(file,'DOORS:YoungGuns/Pistolers/'username'',"R")
  198. gun = readln(file)
  199. bullets = readln(file)
  200. wins = readln(file)
  201. lost = readln(file)
  202. level = readln(file)
  203. exp = readln(file)
  204. money = readln(file)
  205. bankmon = readln(file)
  206. hits = readln(file)
  207. med = readln(file)
  208. alias = readln(file)
  209. call close(file)
  210. if money = 0 | money < 1 then money = 200
  211. if hits = 0 then hits = 20
  212.  
  213. Load:
  214. call open(file,'DOORS:YoungGuns/LastPlayer',"W")
  215. call writeln file, ''alias'';call close(file)
  216. str = ''
  217. call Out
  218. call Bl
  219. str = Cya||'Do you want to read the instructions?['||Yel||'y'||Cya||'/N]'||Off
  220. call GetKey
  221. answer = upper(hot)
  222. if answer  =  'Y' then signal Intro
  223. signal Main
  224.  
  225. Intro:
  226. str = CLS||'                      '||Blu||' _________________________'||Off
  227. call Out
  228. str = '                      '||BluYel||'| Young Guns Instructions |'||Off
  229. call Out
  230. str = '                      '||BluYel||'|_________________________|'||Off
  231. call Out
  232. str = ''
  233. call Out
  234. str = '     Young Guns takes place in the old western days, back when Billy The' 
  235. call Out
  236. str = 'Kid was alive. Now, place yourself in Billy The Kid''s shoes, but you''re not'
  237. call Out
  238. str = 'Billy. You''re you! (Of course!) You must watch what you do or your mission' 
  239. call Out
  240. str = 'will be a failure.'
  241. call Out
  242. str = ''
  243. call Out
  244. str = Cya||'-='||CyaWht||'Object Of The Game'||Off||''||Cya||'=-'||Off
  245. call Out
  246. str = Blu'______________________'Off
  247. call Out
  248. str = ''
  249. call Out
  250. str = '     The object of the game is to rule Young Guns. There are missions you'
  251. call Out
  252. str = 'must go on to test your skills and power. There are a total of 10 missions,' 
  253. call Out
  254. str = 'each tougher as you go along. Also, other players can attack you and'  
  255. call Out
  256. str = 'knock you down a level. The game is not easy, but you can win it if you try.'
  257. call Out
  258. str = 'Don''t give up!'
  259. call Out
  260. call Bl
  261. str = Blu||'-= '||Yel||'Press any key to continue'||Blu||'=-'||Off
  262. call GetKey
  263. answer = upper(hot)
  264. str = CLS
  265. call Out
  266. str = ''
  267. call Out
  268. str = Cya||'-='||CyaWht||'Ending Of The Game'||Off||''||Cya||'=-'||Off
  269. call Out
  270. str = Blu'______________________'Off
  271. call Out
  272. str = ''
  273. call Out
  274. str = '     The game will only end when someone has completed all 10 missions.' 
  275. call Out
  276. str = 'Whoever completes all 10 levels is the winner and a new game must begin'
  277. call Out
  278. str = 'again.  Good luck!'  
  279. call Out
  280. str = ''                       
  281. call Out
  282. str = '                       '||Cya||'-='||CYAWht||'Have fun and enjoy the game'||Off||''||Cya||'=-'||Off
  283. call Out
  284. call Bl
  285. str = BLU||'-=||'Yel||'Press any key to continue'||Blu||'=-'||OFF
  286. call GetKey
  287. answer = upper(hot)
  288. call Main
  289.  
  290. Main:
  291. str = ' '
  292. call Out
  293. call newsflash
  294. timeleft = 30 - time('E') % 60
  295. if timeleft < 1 then do
  296. str = Red 'Your time limit is up.'Off
  297. call Out
  298. address comand "wait 2"
  299. signal bye;end
  300. if hits < 1 then hits = 0
  301. if money < 1 then money = 0
  302. if bullets < 1 then bullets = 0
  303. str = Blu'['Grn'?'||YEL||' = Menu'Blu']'Off
  304. call GetKey
  305. a = upper(hot)
  306. str = CLS
  307. call Out
  308. str = ' '
  309. call Out
  310. if a = "S" then signal Store
  311. if a = "M" then signal Level
  312. if a = "Y" then signal Stats
  313. if a = "P" then signal Practice
  314. if a = "B" then signal Bank
  315. if a = "G" then signal Gamble
  316. if a = "L" then do
  317. filen = 'DOORS:YoungGuns/Players';call lister
  318. str = ''
  319. call Out
  320. end
  321. if a = "F" then signal UFight
  322. if a = "R" then signal News
  323. if a = "H" then call Healer
  324. if a = '#' then signal GetOut
  325. if a = "?" then do
  326. str = CLS
  327. call Out
  328. str = '                           '||BluYel||'-=Young Guns v1.00=-'||Off          
  329. call Out
  330. str = '                              '||Cya||'MebbsNet Version'||Off           
  331. call Out
  332. str = '                          '||Blu' ---------------------'||Off          
  333. call Out
  334. str = '                           '||Blu||'['||Yel||'S'||Blu||'] '||Cya||'Enter the store'||Off             
  335. call Out
  336. str = '                           '||Blu||'['||Yel||'M'||Blu||'] '||Cya||'Go on a mission'||Off         
  337. call Out
  338. str = '                           '||Blu||'['||Yel||'Y'||Blu||'] '||Cya||'View your stats'||Off             
  339. call Out
  340. str = '                           '||Blu||'['||Yel||'P'||Blu||'] '||Cya||'Practice with the computer'||Off      
  341. call Out
  342. str = '                           '||Blu||'['||Yel||'B'||Blu||'] '||Cya||'Enter the bank'||Off             
  343. call Out
  344. str = '                           '||BLU||'['||YEL||'G'||BLU||'] '||CYA||'Gamble your money'Off          
  345. call Out
  346. str = '                           '||BLU||'['||YEL||'L'||BLU||'] '||CYA||'List of other players'Off        
  347. call Out
  348. str = '                           '||BLU||'['||YEL||'F'||BLU||'] '||CYA||'Fight another player'Off       
  349. call Out
  350. str = '                           '||BLU||'['||YEL||'R'||BLU||'] '||CYA||'Read the newspaper'Off        
  351. call Out
  352. str = '                           '||BLU||'['||YEL||'H'||BLU||'] '||CYA||'Heal yourself with medicine'Off
  353. call Out
  354. str = '                           '||BLU||'['||YEL||'Q'||BLU||'] '||CYA||'Quit to'red BBS Off
  355. call Out
  356. call Bl
  357. end
  358. if a = "Q" then do
  359. str = Cya'Are you sure?  ['||YEL||'Y'||CYA||'/n]'Off
  360. call GetKey
  361. q = upper(hot)
  362. str = ' '
  363. call Out
  364. if q = "N" then call main
  365. signal bye
  366. return;end
  367. signal main
  368.  
  369. Newsflash:
  370. if level = 9 then do
  371. str = Red' Buckshot George and Arkansas Dave left due to your crazyness.'Off
  372. call Out
  373. str = Red' They found Old Mexico, and were beheaded.  There wasn''t an Old Mexico.'Off
  374. call Out
  375. end
  376. if level = 0 then do
  377. str = ' '
  378. call Out
  379. end
  380. if level = 7 then do
  381. str = Cya' Doc and Chavez have died in your recent battle.'Off
  382. call Out
  383. str = Cya' You, Arkansas Dave, and Buckshot George are still alive.'Off
  384. call Out
  385. end
  386. if level = 6 then do
  387. str = Cya' There is a new sheriff of Lincoln county, sheriff Pat Garret.'Off
  388. call Out
  389. end
  390. return
  391.  
  392. Stats:
  393. str = CLS
  394. call Out
  395. str = '('alias'''s Stats)'
  396. call Out
  397. str = Yel' Hit Points '||BLU||'- '||CYA||''hits''Off
  398. call Out
  399. str = Yel' Gun        '||BLU||'- '||CYA||''gun''Off
  400. call Out
  401. str = Yel' Wins       '||BLU||'- '||CYA||''wins''Off
  402. call Out
  403. str = Yel' Level      '||BLU||'- '||CYA||''level''Off
  404. call Out
  405. str = Yel' Money      '||BLU||'- '||CYA||''money''Off
  406. call Out
  407. str = Yel' Medicine   '||BLU||'- '||CYA||''med''Off
  408. call Out
  409. str = Yel' Bullets    '||BLU||'- '||CYA||''bullets''Off
  410. call Out
  411. str = Yel' Lost       '||BLU||'- '||CYA||''lost''Off
  412. call Out
  413. str = Yel' Experience '||BLU||'- '||CYA||''exp''Off
  414. call Out
  415. str = Yel' Bank Money '||BLU||'- '||CYA||''bankmon''Off
  416. call Out
  417. signal main
  418.  
  419. Healer:
  420. if level = 0 then do
  421. if hits >= 100 then do
  422. str = Red'You can''t heal anymore!'Off
  423. call Out
  424. return
  425. end
  426. end
  427. if level = 1 then do
  428. if hits = 100 | hits > 100 then do
  429. str = Red'You can''t heal anymore!'Off
  430. call Out
  431. return
  432. end
  433. end
  434. if level = 2 then do
  435. if hits = 200 | hits > 200 then do
  436. str = Red'You can''t heal anymore!'Off
  437. call Out
  438. return
  439. end
  440. end
  441. if level = 3 then do
  442. if hits = 300 | hits > 300 then do
  443. str = Red'You can''t heal anymore!'Off
  444. call Out
  445. return
  446. end
  447. end
  448. if level = 4 then do
  449. if hits = 400 | hits > 400 then do
  450. str = Red'You can''t heal anymore!'Off
  451. call Out
  452. return
  453. end
  454. end
  455. if level = 5 then do
  456. if hits = 500 | hits > 500 then do
  457. str = Red'You can''t heal anymore!'Off
  458. call Out
  459. return
  460. end
  461. end
  462. if level = 6 then do
  463. if hits = 600 | hits > 600 then do
  464. str = Red'You can''t heal anymore!'Off
  465. call Out
  466. return
  467. end
  468. end
  469. if level = 7 then do
  470. if hits = 700 | hits > 700 then do
  471. str = Red'You can''t heal anymore!'Off
  472. call Out
  473. return
  474. end
  475. end
  476. if level = 8 then do
  477. if hits = 800 | hits > 800 then do
  478. str = Red'You can''t heal anymore!'Off
  479. call Out
  480. return
  481. end
  482. end
  483. if level = 9 then do
  484. if hits = 900 | hits > 900 then do
  485. str = Red'You can''t heal anymore!'Off
  486. call Out
  487. return
  488. end
  489. end
  490. if level = 10 then do
  491. if hits = 1000 | hits > 1000 then do
  492. str = Red'You can''t heal anymore!'Off
  493. call Out
  494. return
  495. end
  496. end
  497. if med > 0 then do
  498. str = Blu'You healed 10 hitpoints with medicine.'Off
  499. call Out
  500. address command "wait 1"
  501. med = med - 1
  502. hits = hits + 10
  503. return
  504. end
  505. if med = 0 | med < 1 then do
  506. str = Red'You have no medicine to heal with.'Off
  507. call Out
  508. return
  509. end
  510.  
  511. Shoot:
  512. str = ''
  513. call Out
  514. if gun = 'Old Pistol' then do
  515. randfire = random(1,3,time('s'))
  516. if randfire = 1 then do
  517. str = Blu'You fire at '||YEL||''obj' '||BLU||'and hit, damaging 1 points.'Off
  518. call Out
  519. ohit = ohit - 1
  520. end
  521. if randfire = 2 then do
  522. str = Blu'You fire at '||YEL||''obj' '||BLU||'and hit, damaging 2 points.'Off
  523. call Out
  524. ohit = ohit - 2
  525. end
  526. if randfire = 3 then do
  527. str = Blu'You fire at '||YEL||''obj' '||BLU||'and miss.'Off
  528. call Out
  529. end
  530. bullets = bullets - 1
  531. return
  532. end
  533. if gun = 'Pistol' then do
  534. randfire = random(1,3,time('s'))
  535. if randfire = 1 then do
  536. str = Blu'You fire at '||YEL||''obj' '||BLU||'and hit, damaging 3 points.'Off
  537. call Out
  538. ohit = ohit - 3
  539. end
  540. if randfire = 2 then do
  541. str = Blu'You fire at '||YEL||''obj' '||BLU||'and hit, damaging 2 points.'Off
  542. call Out
  543. ohit = ohit - 2
  544. end
  545. if randfire = 3 then do
  546. str = Blu'You fire at '||YEL||''obj' '||BLU||'and miss.'Off
  547. call Out
  548. end
  549. bullets = bullets - 1
  550. return
  551. end
  552. if gun = 'Long Barrel' then do
  553. randfire = random(1,3,time('s'))
  554. if randfire = 1 then do
  555. str = Blu'You fire at '||YEL||''obj' '||BLU||'and hit, damaging 4 points.'Off
  556. call Out
  557. ohit = ohit - 4
  558. end
  559. if randfire = 2 then do
  560. str = Blu'You fire at '||YEL||''obj' '||BLU||'and hit, damaging 5 points.'Off
  561. call Out
  562. ohit = ohit - 5
  563. end
  564. if randfire = 3 then do
  565. str = Blu'You fire at '||YEL||''obj' '||BLU||'and miss.'Off
  566. call Out
  567. end
  568. bullets = bullets - 1
  569. return
  570. end
  571. if gun = 'Shotgun' then do
  572. randfire = random(1,3,time('s'))
  573. if randfire = 1 then do
  574. str = Blu'You fire at '||YEL||''obj' '||BLU||'and hit, damaging 6 points.'Off
  575. call Out
  576. ohit = ohit - 6
  577. end
  578. if randfire = 2 then do
  579. str = Blu'You fire at '||YEL||''obj' '||BLU||'and hit, damaging 7 points.'Off
  580. call Out
  581. ohit = ohit - 7
  582. end
  583. if randfire = 3 then do
  584. str = Blu'You fire at '||YEL||''obj' '||BLU||'and miss.'Off
  585. call Out
  586. end
  587. bullets = bullets - 1
  588. return
  589. end
  590. if gun = 'Young Gun' then do
  591. randfire = random(1,3,time('s'))
  592. if randfire = 1 then do
  593. str = Blu'You fire at '||YEL||''obj' '||BLU||'and hit, damaging 8 points.'Off
  594. call Out
  595. ohit = ohit - 8
  596. end
  597. if randfire = 2 then do
  598. str = Blu'You fire at '||YEL||''obj' '||BLU||'and hit, damaging 7 points.'Off
  599. call Out
  600. ohit = ohit - 7
  601. end 
  602. if randfire = 3 then do
  603. str = Blu'You fire at '||YEL||''obj' '||BLU||'and miss.'Off
  604. call Out
  605. end
  606. bullets = bullets - 1
  607. return
  608. end
  609.  
  610. Cshoot:
  611. if ogun = 'Old Pistol' then do
  612. randcomp = random(1,3,time('s'))
  613. if randcomp = 1 then do
  614. str = Red'* '||PUR||''obj' 'Red'fires at you and hits, damaging 3 points!'Off
  615. call Out
  616. address command "wait 2"
  617. hits = hits - 3
  618. end
  619. if randcomp = 2 then do
  620. str = Red'* '||PUR||''obj' 'Red'fires at you and hits, damaging 2 points!'Off
  621. call Out
  622. address command "wait 2"
  623. hits = hits - 2 
  624. end
  625. if randcomp = 3 then do
  626. str = Red'* '||PUR||''obj' 'Red'fires at you and misses.'Off
  627. call Out
  628. address command "wait 2"
  629. end
  630. obullets = obullets - 1
  631. return
  632. end
  633. if ogun = 'Pistol' then do
  634. randcomp = random(1,3,time('s'))
  635. if randcomp = 1 then do
  636. str = Red'* '||PUR||''obj' 'Red'fires at you and hits, damaging 4 points!'Off
  637. call Out
  638. address command "wait 2"
  639. hits = hits - 4
  640. end
  641. if randcomp = 2 then do
  642. str = Red'* '||PUR||''obj' 'Red'fires at you and hits, damaging 3 points!'Off
  643. call Out
  644. address command "wait 2"
  645. hits = hits - 3
  646. end
  647. if randcomp = 3 then do
  648. str = Red'* '||PUR||''obj' 'Red'fires at you and misses.'Off
  649. call Out
  650. address command "wait 2"
  651. end
  652. obullets = obullets - 1
  653. return
  654. end
  655. if ogun = 'Long Barrel' then do
  656. randcomp = random(1,3,time('s'))
  657. if randcomp = 1 then do
  658. str = Red'* '||PUR||''obj' 'Red'fires at you and hits, damaging 5 points!'Off
  659. call Out
  660. address command "wait 2"
  661. hits = hits - 5
  662. end
  663. if randcomp = 2 then do
  664. str = Red'* '||PUR||''obj' 'Red'fires at you and hits, damaging 4 points!'Off
  665. call Out
  666. address command "wait 2"
  667. hits = hits - 4
  668. end
  669. if randcomp = 3 then do
  670. str = Red'* '||PUR||''obj' 'Red'fires at you and misses.'Off
  671. call Out
  672. addrress command "wait 2"
  673. end
  674. obullets = obullets - 1
  675. return
  676. end
  677. if ogun = 'Shotgun' then do
  678. randcomp = random(1,3,time('s'))
  679. if randcomp = 1 then do
  680. str = Red'* '||PUR||''obj' 'Red'fires at you and hits, damaging 6 points!'Off
  681. call Out
  682. address command "wait 2"
  683. hits = hits - 6
  684. end
  685. if randcomp = 2 then do
  686. str = Red'* '||PUR||''obj' 'Red'fires at you and hits, damaging 5 points!'Off
  687. call Out
  688. address command "wait 2"
  689. hits = hits - 5
  690. end
  691. if randcomp = 3 then do
  692. str = Red'* '||PUR||''obj' 'Red'fires at you and misses.'Off
  693. call Out
  694. address command "wait 2"
  695. end
  696. obullets = obullets - 1
  697. return
  698. end
  699. if ogun = 'Young Gun' then do
  700. randcomp = random(1,3,time('s'))
  701. if randcomp = 1 then do
  702. str = Red'* '||PUR||''obj' 'Red'fires at you and hits, damaging 7 points!'Off
  703. call Out
  704. address command "wait 2"
  705. hits = hits - 7
  706. end
  707. if randcomp = 2 then do
  708. str = Red'* '||PUR||''obj' 'Red'fires at you and hits, damaging 6 points!'Off
  709. call Out
  710. address command "wait 2"
  711. hits = hits - 6
  712. end
  713. if randcomp = 3 then do
  714. str = Red'* '||PUR||''obj' 'Red'fires at you and misses.'Off
  715. call Out
  716. address command "wait 2"
  717. end
  718. obullets = obullets - 1
  719. return
  720. end
  721.  
  722. Store:
  723. str = CLS
  724. call Out
  725. str = ''
  726. call Out
  727. str = '                         '||BLU||'---=== '||CYA||'Store Menu '||BLU||'===---'Off
  728. call Out
  729. str = '               '||YEL||'+__+_____+_________________________+_____+__+'
  730. call Out
  731. str = '               'Wht'|  |     '||YEL||'|  '||BLU||'['||YEL||'G'||BLU||'] '||CYA||'Buy a new gun'||YEL||'      |     'Wht'|  |'Off
  732. call Out
  733. str = '               'Wht'|  |     '||YEL||'|  '||BLU||'['||YEL||'S'||BLU||'] '||CYA||'Sell your gun'||YEL||'      |     'Wht'|  |'Off
  734. call Out
  735. str = '               'Wht'|  |     '||YEL||'|  '||BLU||'['||YEL||'M'||BLU||'] '||CYA||'Buy some medicine'||YEL||'  |     'Wht'|  |'Off
  736. call Out
  737. str = '               'Wht'|  |     '||YEL||'|  '||BLU||'['||YEL||'B'||BLU||'] '||CYA||'Buy some bullets'||YEL||'   |     'Wht'|  |'Off
  738. call Out
  739. str = '               'Wht'|  |     '||YEL||'|  '||BLU||'['||YEL||'Q'||BLU||'] '||CYA||'Leave the store'||YEL||'    |     'Wht'|  |'Off
  740. call Out
  741. str = '               'Wht'|  |     '||YEL||'|_________________________|     'Wht'|  |'Off
  742. call Out
  743. str = '              'Grn'\'Wht'|  |'Grn'/                                   \'Wht'|  |'Grn'/'Off
  744. call Out
  745. str = ''
  746. call Out
  747. call Bl
  748. str = Blu 'May I help you with something?' Off
  749. call GetKey
  750. p = upper(hot)
  751. str = ''
  752. call Out
  753. if p = "G" then do
  754. call bgun;end
  755. if p = "S" then call sgun
  756. if p = "M" then call medicine
  757. if p = "B" then call ammo
  758. if p = "Q" then call main
  759. signal store
  760.  
  761. bgun:
  762. str = CLS
  763. call Out
  764. str = CYA 'Here''s what we have in stock:' OFF 
  765. call Out
  766. str = ' '
  767. call Out
  768. str = '                       '||CYA||'---=== '||BLU||'Guns Menu '||CYA||'===---'Off
  769. call Out
  770. str = '                            '||YEL||'-------------'Off
  771. call Out
  772. str = '                       '||BLU||'['||YEL||'P'||BLU||'] '||CYA||'Pistol      '||YEL||'- 'Grn'$1000'Off
  773. call Out
  774. str = '                       '||BLU||'['||YEL||'B'||BLU||'] '||CYA||'Long Barrel '||YEL||'- 'Grn'$2000'Off
  775. call Out
  776. str = '                       '||BLU||'['||YEL||'S'||BLU||'] '||CYA||'Shotgun     '||YEL||'- 'Grn'$3000'Off
  777. call Out
  778. str = '                       '||BLU||'['||YEL||'Y'||BLU||'] '||CYA||'Young Gun   '||YEL||'- 'Grn'$4000'Off
  779. call Out
  780. str = ' '
  781. call Out
  782. call Bl
  783. str = Blu' What may you be intrested in? ['||PUR||'Q'||BLU||'] = Quit to Front store]'Off
  784. call GetKey
  785. c = upper(hot)
  786. str = ''
  787. call Out
  788. if c = "Q" then signal store
  789. if c = "P" then do
  790. if money < 1000 then do
  791. call Nmoney
  792. call bgun;end
  793. if money > 1000 | money = 1000 then do
  794. str = Yel'The Pistol is now yours, be careful!'Off
  795. call Out
  796. call Bl
  797. str = RED "Hit [RETURN] "
  798. call GetKey
  799. answer = upper(hot)
  800. money = money - 1000
  801. gun = 'Pistol';signal store;end;end
  802. if c = "B" then do
  803. if money < 2000 then do
  804. call Nmoney;call bgun;end
  805. if money > 2000 | money = 2000 then do
  806. str = Yel'The Long Barrel is now yours, be careful!'Off
  807. call Out
  808. call Bl
  809. str = RED "Hit [RETURN]"
  810. call GetKey
  811. aswer = Upper(hot)
  812. gun = 'Long Barrel';money = money - 2000;call store;end;end
  813. if c = "S" then do
  814. if money < 3000 then do
  815. call Nmoney;call bgun;end
  816. if money > 3000 | money = 3000 then do
  817. str = Yel'The Shotgun is yours, be careful!'Off
  818. call Out
  819. call Bl
  820. str = RED "Hit [RETURN]"
  821. call GetKey
  822. answer = upper(hot)
  823. gun = 'Shotgun'
  824. money = money - 3000;call store;end;end
  825. if c = "Y" then do
  826. if money < 4000 then do
  827. call Nmoney;call bgun;end
  828. if money > 4000 | money = 4000 then do
  829. str = Yel'The Young Gun is yours, be careful!'Off
  830. call Out
  831. call Bl
  832. str = RED "Hit [RETURN]"
  833. call GetKey
  834. answer = upper(hot)
  835. gun = 'Young Gun';money = money - 4000;call store;end;end
  836. call bgun
  837.  
  838. Nmoney:
  839. str = ' '
  840. call Out
  841. str =  Red'Sorry, you need more money!'Off
  842. call Out
  843. call Bl
  844. str = RED "Hit [RETURN]"
  845. call GetKey
  846. answer = upper(hot)
  847. return
  848.  
  849. Practice:
  850. if hits = 0 | hits < 1 then do
  851. str = ' '
  852. call Out
  853. str = Red'Sorry, you need hitpoints to practice.'Off
  854. call Out
  855. str = RED'Hit [RETURN]'OFF
  856. call GetKey
  857. answer = hot
  858. call main;end
  859. if bullets = 0 | bullets < 1 then do
  860. str = Red ' Sorry, you need bullets to fight.'Off
  861. call Out
  862. call Bl
  863. str = RED "Hit [RETURN]"
  864. call GetKey
  865. answer = upper(hot)
  866. call main;end
  867. randprac = random(1,3,time('s'))
  868. if randprac = 1 then obj = ''||PUR||'Clint Eastwood'Off
  869. if randprac = 2 then obj = ''||YEL||'Quick Shot'Off
  870. if randprac = 3 then obj = ''||CYA||'Buford Tannen'Off
  871. str = 'You will be fighting 'obj'.'
  872. call Out
  873. if obj = Pur'Clint Eastwood'Off then call Clint
  874. if obj = Yel'Quick Shot'Off then call Quick
  875. if obj = Cya'Buford Tannen'Off then call Buford
  876. signal Practice!
  877.  
  878. Clint:
  879. ohit = 20
  880. obullets = 20
  881. ogun = 'Old Pistol'
  882. return
  883. Quick:
  884. ohit = 19
  885. obullets = 19
  886. ogun = 'Old Pistol'
  887. return
  888. Buford:
  889. ohit = 19
  890. obullets = 21
  891. ogun = 'Old Pistol'
  892. return
  893.  
  894. Practice!:
  895. if hits = 0 | hits < 0 then do
  896. str = Blu'You lost your practice, try again sometime.'Off
  897. call Out
  898. signal main;end
  899. if bullets = 0 | bullets < 0 then do
  900. str = Red'You lose, next time have enough bullets.'Off
  901. call Out
  902. signal main;end
  903. if ohit = 0 | ohit < 1 then do
  904. str = Grn'You win!  Nice shooting.  Here''s your bonus!'Off
  905. call Out
  906. call bonus;end
  907. if obullets = 0 | obullets < 0 then do
  908. str = Grn||'You win! '||Cya||''obj' '||Grn||'ran out of bullets.  Here''s your bonus.'||Off
  909. call Out
  910. call bonus;end
  911. str = '(Your hits '||Pur||':'||Off||' '||Cya||''hits''||Off||') (Your bullets '||Pur||':'||Off||' '||Cya||''bullets')'||Off
  912. call Out
  913. str = '('||Pur||''obj'''s'||Off||' hits '||Yel||':'||Off||' '||Red||''ohit''||Off||') ('||Pur||''obj'''s'||Off||' bullets '||Yel||':'||Off||' '||RED||''obullets')'||Off
  914. call Out
  915. str = Blu||'['||Yel||'F'||Blu||']'||Off||' Fire at 'obj
  916. call Out
  917. str = Blu||'['||Yel||'Q'||Blu||']'||Off||' Quit and give up'
  918. call Out
  919. str = YEL 'Command '||PUR||'->'Off
  920. call GetKey
  921. n = upper(hot)
  922. str = CLS
  923. call Out
  924. if n = "Q" then call main
  925. if n = "F" then do
  926. call shoot;call cshoot;end
  927. signal practice!
  928.  
  929. Lister:
  930. call open(player,filen,'R')
  931. x = 0
  932. do until eof(player) = 1
  933. x = x + 1
  934. line = readln(player)
  935. parse var line uName':'uAlias
  936. uname.x = uname
  937. ualias.x = ualias
  938. end
  939. call close player
  940. numplayers = x - 1
  941. str = ' '
  942. call Out
  943. do i = 1 to numplayers
  944. a = right('     'i,6)||'. 'ualias.i
  945. str = left(a,49)
  946. call Out
  947. end;return
  948.  
  949. Bank:
  950. str = CLS
  951. call Out
  952. str = ' '
  953. call Out
  954. str = '                         '||Grn||'---=== '||Cya||'Bank Menu '||Grn||'===---'||Off
  955. call Out
  956. str = '                              '||Grn||'-------------'||Off
  957. call Out
  958. str = '                          '||Blu||'['||Yel||'D'||Blu||'] '||Cya||'Deposit money'||Off
  959. call Out
  960. str = '                          '||Blu||'['||Yel||'W'||Blu||'] '||Cya||'Withdraw money'||Off
  961. call Out
  962. str = '                          '||Blu||'['||Yel||'Q'||Blu||'] '||Cya||'Quit to town'||Off
  963. call Out
  964. str = ''
  965. call Out
  966. str = Blu||'['||Cya||'Bank'||Blu||'] '||Grn||'How may I help you today? '||Off
  967. call GetKey
  968. d = upper(hot)
  969. str = ''
  970. call Out
  971. if d = "Q" then call Main
  972. if d = "D" then call Deposit
  973. if d = "W" then call Withd
  974.  
  975. Deposit:
  976. str = Blu'['||Pur||'Money = 'money''||Blu||'] '
  977. call Out
  978. str = Cya||'Deposit how much money? ['||Yel||'Q'||Cya||'] = Quit to front bank->'||Grn||'$'Off
  979. length = 10 
  980. call Input
  981. e = upper(typed)
  982. if e = "0" then call Bank
  983. if e = "" then call Bank
  984. if e = "q" | e = "Q" then call bank
  985. if e > money then do
  986. str = Red'You don''t have that much money!'Off
  987. call Out
  988. address command "wait 2"
  989. signal Bank
  990. end
  991. if e < money | e = money then do
  992. str = Grn' 'e' '||YEL||' deposited.'Off
  993. call Out
  994. address command "wait 2"
  995. bankmon = bankmon + e;money = money - e;call bank
  996. signal Bank
  997. end
  998.  
  999. WithD:
  1000. str = Wht||'['||Cya||'Money In Bank = 'bankmon''||Wht||'] 'Off
  1001. call Out
  1002. str = Cya||'Withdraw how much? ['||Wht||'Q'||Cya||' = Quit to front bank]->'||Grn||'$'||Off
  1003. call Out
  1004. length = 10
  1005. call Input
  1006. f = upper(typed)
  1007. str = ''
  1008. call Out
  1009. if f = "0" then call WithD
  1010. if f = "q" | f = "Q" then call bank
  1011. if f = "" then signal Withd
  1012. if f > e then do
  1013. str = Red|| 'You don''t have that much money!'||Off
  1014. call Out
  1015. address command "wait 2"
  1016. call Withd;end
  1017. if f < e | f = e then do
  1018. str = Grn||''f''||Yel||' withdrawn.'||Off
  1019. call Out
  1020. address command "wait 2"
  1021. bankmon = bankmon - f;money = money + f;call bank
  1022. signal WithD
  1023. end
  1024.  
  1025. Ammo:
  1026. if bullets > 200 | bullets = 200 then do
  1027. call Bl
  1028. str = Red|| 'You have your limit in bullets.'||Off
  1029. call Out
  1030. address command "wait 1"
  1031. signal main;end
  1032. else do
  1033. str = CLS
  1034. call Out 
  1035. call BL
  1036. str = '                       '||Cya||'---=== '||Wht||'Bullets Menu '||Cya||'===---'||Off
  1037. call Out
  1038. str = '                            '||Pur||'----------------'||Off
  1039. call Out
  1040. str = '                    '||Blu||'['||Yel||'B'||Blu||'] '||Cya||'Buy 50 bullets - '||Grn||'$100'||Off
  1041. call Out
  1042. str = '                    '||Blu||'['||Yel||'Q'||Blu||'] '||Cya||'Quit to town'||Off
  1043. call Out
  1044. str = ''
  1045. call Out
  1046. str = Blu||'['||Yel||'Bullet store'||BLU||']'
  1047. call Out
  1048. str = Red||'What can I get for you?'||RED||'['||Cya||'Q'||Red||' = Quit to front store] '||Off
  1049. call GetKey
  1050. g = upper(hot)
  1051. call Bl
  1052. if g = "B" then do
  1053. if money < 100 then do
  1054. str = Red 'You don''t have that much money!'Off
  1055. call Out
  1056. address command "wait 2"
  1057. signal Ammo;end;end
  1058. if money > 100 | money = 100 then do
  1059. str = Cya||'You bought 50 bullets.'||Off
  1060. call Out
  1061. address command "wait 2"
  1062. money = money - 100
  1063. bullets = bullets + 50
  1064. end
  1065. if g = "Q" then call store
  1066. signal Ammo
  1067.  
  1068. Ufight:
  1069. if hits = 0 | hits < 1 then do
  1070. str = Red'Sorry, your hitpoints are too low.'Off
  1071. call Out
  1072. address command "wait 2"
  1073. call main;end
  1074. if bullet = 0 | bullets < 1 then do
  1075. str = Red'Sorry, you must have some bullets to fight.'Off
  1076. call Out
  1077. address command "wait 2"
  1078. call main;end
  1079. filen = 'DOORS:YoungGuns/Players'
  1080. call lister
  1081. str = ' '
  1082. call Out
  1083. str = Blu||'['||Pur||'User Battle'||Blu||'] 'Off
  1084. call Out
  1085. str = Yel||'Which user do you want to fight?'||CYA||'(Enter player number)'||Off
  1086. call Out
  1087. str = Blu||'['||Pur||'Q'||Blu||']'||PUR||' = Quit to town-> '||Off
  1088. call GetKey
  1089. x = upper(hot)
  1090. str = ''
  1091. call Out
  1092. if x = "Q" then call main
  1093. if x = '' then call Ufight
  1094. if x < 1 | x > numplayers then call Ufight
  1095. Filename = 'DOORS:YoungGuns/Pistolers/'uname.x
  1096. if uname.x = username then do 
  1097. str = Red||'You '||Yel||'dummy'||Red||', you can''t attack yourself!'||Off
  1098. call Out
  1099. address command "wait 2"
  1100. call Ufight
  1101. end
  1102. if ~exists(filename) then do
  1103. str = Red'There''s no player under that name.'Off
  1104. call Out
  1105. address command "wait 2"
  1106. call Ufight
  1107. end
  1108. obj = ualias.x
  1109.  
  1110. Getfighter:
  1111. call open(file,filename,"R")
  1112. ogun = readln(file)
  1113. obullets = readln(file)
  1114. owins = readln(file)
  1115. olost = readln(file)
  1116. olevel = readln(file)
  1117. oexp = readln(file)
  1118. omoney = readln(file)
  1119. obankmon = readln(file)
  1120. ohit = readln(file)
  1121. omed = readln(file)
  1122. oalias = readln(file)
  1123. call close(file)
  1124.  
  1125. if obullets = 0 | obullets < 1 then do
  1126. str = Yel||'Sorry, '||Blu||''obj''||Yel||' is out of bullets.  He will not fight.'||Off
  1127. call Out
  1128. address command "wait 2"
  1129. call Ufight;end
  1130. if ohit = 0 | ohit < 1 then do
  1131. str = Yel||'Sorry, '||Blu||''obj''||Yel||' is hurt too bad to fight.'||Off
  1132. call Out
  1133. address command "wait 2"
  1134. call Ufight;end
  1135. str = ''
  1136. call Out
  1137. str = CLS
  1138. call Out
  1139. str = Blu''obj'''s stats file 'Off
  1140. call Out
  1141. str = Cya'Hit points '||BLU||'- '||YEL||''ohit''Off
  1142. call Out
  1143. str = Cya'Gun        '||BLU||'- '||YEL||''ogun''Off
  1144. call Out
  1145. str = Cya'Wins       '||BLU||'- '||YEL||''owins''Off
  1146. call Out
  1147. str = Cya'Money      '||BLU||'- '||YEL||''omoney''Off
  1148. call Out
  1149. str = Cya'Bullets    '||BLU||'- '||YEL||''obullets''Off
  1150. call Out
  1151. str = Cya'Lost       '||BLU||'- '||YEL||''olost''Off
  1152. call Out
  1153. str = Cya||'Experience '||Blu||'- '||Yel||''oexp''||Off
  1154. call Out
  1155. call Bl
  1156. str = Blu||'Are you sure you want to fight this user? ['||Yel||'Y'||Blu||'/n]'||Off
  1157. call GetKey
  1158. h = upper(hot)
  1159. str = ''
  1160. call Out
  1161. if h = "N" then call Ufight
  1162. signal Ufight!
  1163.  
  1164. Ufight!:
  1165. if hit = 0 | hit < 1 then do
  1166. str = Red'Sorry, you lose.  Try again later.'Off
  1167. call Out
  1168. call Bl
  1169. str = RED'Hit [RETURN]'
  1170. call GetKey
  1171. answer = hot
  1172. lost = lost + 1
  1173. lo = 1
  1174. call winlose;end
  1175. if ohit = 0 | ohit < 1 then do
  1176. str = Pur||'Congratulations!  You beat '||Blu||''obj''||Pur||'!'||Off
  1177. call Out
  1178. address command "wait 2"
  1179. wins = wins + 1
  1180. wi = 1
  1181. call winlose;end
  1182. if obullets = 0 | obullets < 1 then do
  1183. str = Pur||'Congratulations! '||Blu||''obj' '||Pur||'has run out of bullets!  You win!'||Off
  1184. call Out
  1185. address command "wait 2"
  1186. wins = wins + 1
  1187. wi = 1
  1188. call winlose;end
  1189. if bullets = 0 | bullets < 1 then do
  1190. str = Red'Sorry, you lose.  Next time check your bullets.'Off
  1191. call Out
  1192. address command "wait 2"
  1193. lost = lost + 1
  1194. lo = 1
  1195. call winlose;end
  1196. if hits = 0 | hits < 1 then do
  1197. str = Red'Sorry, you lose.  Next time come prepared.'Off
  1198. call Out
  1199. address command "wait 2"
  1200. lost = lost + 1
  1201. lo = 1
  1202. call winlose;end
  1203. str = CLS
  1204. call Out
  1205. str = '(Your hit points '||Cya||':'||Off||' '||Yel||''hits''||Off||' (Your bullets '||Cya||': '||Yel||''bullets')'||Off  
  1206. call Out
  1207. str = '('obj'''s hit points '||Red||': '||Blu||''ohit''||Off||' ('obj'''s bullets '||Red||': '||Blu||''obullets')'||Off
  1208. call Out
  1209. str = Blu||'['||Yel||'F'||Blu||'] '||Cya||'- '||Blu||'Fire at 'obj''||Off||' '||Yel||' '||Off 
  1210. call Out
  1211. str = Blu||'['||Yel||'Q'||Blu||'] '||Cya||'-'||Off||' '||Blu||'Quit and give up'||Off
  1212. call Out
  1213. str = Pur'Option'||YEL||'-> 'Off
  1214. call GetKey
  1215. i = upper(hot)
  1216. str = ''
  1217. call Out
  1218. if i = "Q" then do
  1219. str = CLS
  1220. call Out
  1221. str = Yel'Chicken...!'Off
  1222. call Out
  1223. call main;end
  1224. if i = "F" then do
  1225. call shoot;call cshoot;end
  1226. if i = "" then call Ufight!
  1227. signal Ufight!
  1228.  
  1229. Medicine:
  1230. str = CLS
  1231. call Out
  1232. str = ' '
  1233. call Out
  1234. str = '                    '||Cya||'---=== '||Wht||'Medicine Menu '||Cya||'===---'||Off
  1235. call Out
  1236. str = '                         -----------------'
  1237. call Out
  1238. str = ''     
  1239. call Out
  1240. str = '                '||Blu||'['||Yel||'B'||Blu||'] '||Cya||'Buy a 10 pack of 10 medicine for '||Grn||'$50'||Off
  1241. call Out
  1242. str = '                '||Blu||'['||Yel||'Q'||Blu||'] '||Cya||'Quit to the store'||Off
  1243. call Out
  1244. call Bl
  1245. str = Wht||'What can I do for you today? ['||Yel||'Q'||Wht||'] = Quit to store] >'|| Off
  1246. call GetKey
  1247. j = upper(hot)
  1248. call Bl
  1249. if j = "B" then do
  1250. if money < 50 then do
  1251. str = Red 'Sorry, you don''t have enough money.'Off
  1252. call Out
  1253. address command "wait 2"
  1254. signal Medicine;end
  1255. if money > 50 then do
  1256. str = Cya'10 pack of medicine sold.'Off
  1257. call Out
  1258. address command "wait 2"
  1259. money = money - 50
  1260. med = med + 10
  1261. signal medicine;end;end
  1262. if j = "Q" then signal store
  1263. signal medicine
  1264.  
  1265. Gamble:
  1266. if money < 1 then do
  1267. str = Red'Sorry, you don''t have any money to gamble.'Off
  1268. call Out
  1269. address command "wait 2"
  1270. signal main;end
  1271. str = CLS
  1272. call Out
  1273. str = ' '
  1274. call Out
  1275. str = '                       '||Cya||'---=== '||Blu||'Gambling Menu '||Cya||'===---'||Off
  1276. call Out
  1277. str = '                            '||Yel||'-----------------'
  1278. call Out
  1279. str = '                         '||Blu||'['||Yel||'P'||Blu||'] '||Cya||'Play the Guessing Game'||Off
  1280. call Out
  1281. str = '                         '||Blu||'['||Yel||'Q'||Blu||'] '||Cya||'Quit to town'||Off
  1282. call Out
  1283. str = ''
  1284. call Out
  1285. str = Blu||'['||Cya||'Gambling room'||Blu||'] 'Off
  1286. call Out
  1287. str = Grn||'What would you like to play? ['||Yel||'Q'||Grn||' = Quit to town] '||Off
  1288. call GetKey
  1289. k = upper(hot)
  1290. str = ''
  1291. call Out
  1292. if k = "P" then call Guess
  1293. if k = "Q" then call main
  1294. signal Gamble
  1295.  
  1296. Guess:
  1297. if money < 100 then do
  1298. str = Red'Sorry, you need 'Grn'$100 'Red'to play.'Off
  1299. call Out
  1300. address command "wait 2"
  1301. call main;end
  1302. randnum = random(1,5,time('s'))
  1303. if randnum = 1 then num = 1
  1304. if randnum = 2 then num = 2
  1305. if randnum = 3 then num = 3
  1306. if randnum = 4 then num = 4
  1307. if randnum = 5 then num = 5
  1308. str = Blu||'['||Yel||'Pick a number 1-5'||Blu||'] ->'||Off
  1309. call GetKey
  1310. l = upper(hot)
  1311. str = ''
  1312. call Out
  1313. if l > 5 then do
  1314. str = Cya||'Enter 1-5 only '||Yel||'-'||Cya||'>'Off
  1315. call GetKey
  1316. l = upper(hot)
  1317. signal Guess;end
  1318. if l = num then do
  1319. str = Yel||'You guessed the number!  You receieve '||Grn||'200 dollars'||Yel||'!'||Off
  1320. call Out
  1321. address command "wait 2"
  1322. money = money + 300
  1323. signal Gamble;end
  1324. str = Yel||'Sorry, you didn''t get the number.  You lose '||Grn||'$100.'||Off
  1325. call Out
  1326. address command "wait 2"
  1327. money = money - 100
  1328. signal gamble;end
  1329. signal Guess
  1330.  
  1331. Bonus:
  1332. exp = exp + 20
  1333. randbon = random(1,3,time('s'))
  1334. if randbon = 1 then do
  1335. str = Yel||'You get '||Grn||'$300'||Yel||', 5 medicines and 20 experience points.'||Off
  1336. call Out
  1337. money = money + 300
  1338. med = med + 5
  1339. end
  1340. if randbon = 2 then do
  1341. str = Yel||'You get '||Grn||'$200'||Yel||', 10 medicines and 20 experience points.'||Off
  1342. call Out
  1343. money = money + 200
  1344. med = med + 10
  1345. end
  1346. if randbon = 3 then do
  1347. str = Yel||'You get '||Grn||'$350'||Yel||', 10 medicines and 20 experience points.'||Off
  1348. call Out
  1349. money = money + 350
  1350. med = med + 10
  1351. end
  1352. signal main
  1353.  
  1354. News:
  1355. if ~exists('DOORS:YoungGuns/Newspaper') then do
  1356. str = 'The newspaper is still in publishing.'
  1357. call Out
  1358. signal main;end
  1359. call readfile dn,ln, "DOORS:YoungGuns/Newspaper" 
  1360. signal main;end
  1361.  
  1362. Winlose:
  1363. if wi = 1 then do
  1364. str = Cya||'You get '||Grn||'$'omoney' '||Cya||'from '||Yel||''obj'''s '||Cya||'pocket.'||Off
  1365. call Out
  1366. address command "wait 2"
  1367. money = money + omoney
  1368. omoney = 0
  1369. if olevel = 0 then olevel = 1
  1370. olevel = olevel - 1
  1371. end
  1372. if lo = 1 then do
  1373. str = Cya||'You lost '||Grn||'$'omoney'.   '||Yel||''obj' '||Cya||'took it from you!'||Off
  1374. call Out
  1375. address command "wait 2"
  1376. omoney = omoney + money
  1377. money = 0
  1378. end
  1379. call open(file,filename,"W")
  1380. call writeln file, ogun;call writeln file, obullets;call writeln file, owins
  1381. call writeln file, olost;call writeln file, olevel;call writeln file, oexp
  1382. call writeln file, omoney;call writeln file, obankmon;call writeln file, ohit
  1383. call writeln file, omed;call writeln file, oalias
  1384. call close(file)
  1385. if lo = 1 then do
  1386. if ~exists('DOORS:YoungGuns/Mail/'oalias) then do
  1387. call open(file,'DOORS:YoungGuns/Mail/'oalias,"W")
  1388. call writeln file, alias' attacked you and lost.  You were to powerful!'
  1389. call close(file);lo = 0;call main;end
  1390. call open(file,'DOORS:YoungGuns/Mail/'oalias,"A")
  1391. call writeln file, alias' attacked you and lost.  You were to powerful!'
  1392. call close(file);lo = 0;call main;end
  1393. if wi = 1 then do
  1394. if ~exists('DOORS:YoungGuns/Mail/'oalias) then do
  1395. call open(file,'DOORS:YoungGuns/Mail/'oalias,"W")
  1396. call writeln file, alias' attacked you and won!'
  1397. call close(file);wi = 0;call main;end
  1398. call open(file,'DOORS:YoungGuns/Mail/'oalias,"A")
  1399. call writeln file, alias' attacked you and won!'
  1400. call close(file);wi = 0;call main;end
  1401.  
  1402. Level:
  1403. if hits = 0 | hits < 1 then do
  1404. str = Red'Sorry, you need hitpoints to fight.'Off
  1405. call Out
  1406. address command "wait 2"
  1407. signal main;end
  1408. if bullets = 0 | bullets < 1 then do
  1409. str = Red'Sorry, you need bullets to fight, go get some.'Off
  1410. call Out
  1411. address command "wait 2"
  1412. signal main;end
  1413. if level = 0 then call Level1
  1414. if level = 1 then call Level2
  1415. if level = 2 then call Level3
  1416. if level = 3 then call Level4
  1417. if level = 4 then call Level5
  1418. if level = 5 then call Level6
  1419. if level = 6 then call Level7
  1420. if level = 7 then call Level8
  1421. if level = 8 then call Level9
  1422. if level = 9 then call Level10
  1423. if level = 10 then 
  1424. str = Pur'You have no more levels!  You have won!  Please'Off
  1425. call Out
  1426. str = Pur'tell your SysOp to reset Young Guns now that you''ve won.'Off
  1427. call Out
  1428. address command "wait 2"
  1429. signal main
  1430.  
  1431. Level1:
  1432. lev = 1
  1433. ogun = 'Young Gun'
  1434. obj = 'The Wagon'
  1435. ohit = 100
  1436. obullets = 100
  1437. str = CLS
  1438. call Out
  1439. str = ' '
  1440. call Out
  1441. str = '             '||CYA||' _____________________________________________'Off
  1442. call Out
  1443. str = '             'CyaBlu'| Level 1 - Take out the Lincoln Men''s wagon |'Off
  1444. call Out
  1445. str = '             'CyaBlu'|____________________________________________|'Off
  1446. call Out
  1447. str = '' 
  1448. call Out
  1449. str = '      You must destory the Lincoln Men''s wagon, because it''s blocking'
  1450. call Out
  1451. str = ' the path that you''re on. Make sure you are prepared with the bullets and'
  1452. call Out
  1453. str = ' hitpoints. Medicine will also help in this procedure.  Good luck!'
  1454. call Out
  1455. str = ''
  1456. call Out
  1457. str = Cya||'Are you ready for this mission? ['||Yel||'Y'||Cya||'/n]'||Off
  1458. call GetKey
  1459. n = upper(hot)
  1460. str = ''
  1461. call Out
  1462. if n = "N" then call main
  1463. signal Level11
  1464.  
  1465. Checklev:
  1466. if ohit = 0 | ohit < 1 then do
  1467. str = Pur||'You have beaten '||Yel||''obj''||Pur||', nice going!'||Off
  1468. call Out
  1469. levw = 1
  1470. call levelsave;end
  1471. if obullets = 0 | obullets < 1 then do
  1472. str = Yel||''obj' '||Pur||'has ran out of bullets. You win, nice going!'||Off
  1473. call Out
  1474. levw = 1
  1475. call Levelsave;end
  1476. if hits = 0 | hits < 1 then do
  1477. str = Pur||'You have failed the mission, watch your hit points next time!'||Off
  1478. call Out
  1479. levl = 1
  1480. call Levelsave;end
  1481. if bullets = 0 | bullets < 1 then do
  1482. str = Pur||'You have failed the mission, next time watch your bullets!'||Off
  1483. call Out
  1484. levl = 1
  1485. call Levelsave;end
  1486. return
  1487.  
  1488. Level11:
  1489. call checklev
  1490. call levelstats
  1491. str = Blu'Command '||YEL||'->'Off
  1492. call GetKey
  1493. o = upper(hot)
  1494. str = ''
  1495. call Out
  1496. if o = "F" then do
  1497. call shoot
  1498. call cshoot
  1499. end
  1500. if o = "H" then call healer
  1501. if o = "Q" then call levelquit
  1502. signal Level11
  1503.  
  1504. Levelsave:
  1505. if level = 10 then do
  1506. if levw = 1 then do
  1507. str = Yel||'Congratulations'||Pur||'!  '||Yel||'You have won '||BluYel||'Young Guns'||Pur||'!'||Off
  1508. call Out
  1509. str = Yel||'Please tell your SysOp to reset Young Guns now that you''ve won.'||Off
  1510. call Out
  1511. address command "wait 2"
  1512. end
  1513. if levl = 1 then do
  1514. str = Red||'Sorry, you lost, now you are level 1 again!  Next time play smart!'||Off
  1515. call Out
  1516. address command "wait 2"
  1517. lev = 0;level = 0;end
  1518. end
  1519. time = date() 
  1520. if levw = 1 then do
  1521. if lev = 1 then level = 1
  1522. if lev = 2 then level = 2
  1523. if lev = 3 then level = 3
  1524. if lev = 4 then level = 4
  1525. if lev = 5 then level = 5
  1526. if lev = 6 then level = 6
  1527. if lev = 7 then level = 7
  1528. if lev = 8 then level = 8
  1529. if lev = 9 then level = 9
  1530. if lev = 10 then level = 10
  1531. str = Blu||'You are awarded '||Grn||'$1000 dollars.'||Off
  1532. call Out
  1533. money = money + 1000
  1534. if ~exists('DOORS:YoungGuns/Newspaper') then do
  1535. call open(file,'DOORS:YoungGuns/Newspaper',"W")
  1536. call writeln file, ''alias' completed level 'lev' on 'time'.'
  1537. call close(file);levw = 0;signal main;end
  1538. if exists('DOORS:YoungGuns/Newspaper') then do
  1539. call open(file,'DOORS:YoungGuns/Newspaper',"A")
  1540. call writeln file, ''alias' completed level 'lev' on 'time'.'
  1541. call close(file);levw = 0;signal main;end
  1542. levw = 0;signal main;end
  1543. if levl = 1 then do
  1544. if ~exists('DOORS:YoungGuns/Newspaper') then do
  1545. call open(file,'DOORS:YoungGuns/Newspaper',"W")
  1546. call writeln file,  ''alias' has failed level 'lev' on 'time'.'
  1547. call close(file);levl = 0;signal main;end
  1548. if exists('DOORS:YoungGuns/Newspaper') then do
  1549. call open(file,'DOORS:YoungGuns/Newspaper',"A")
  1550. call writeln file,  ''alias' has failed level 'lev' on 'time'.'
  1551. call close(file);levl = 0;signal main;end
  1552. levl = 0;signal main;end
  1553. signal main
  1554.  
  1555. Nolevel:
  1556. str = Red'Sorry, that level is not yet available.'Off
  1557. call Out
  1558. address command "wait 2"
  1559. Signal main
  1560.  
  1561. Level2:
  1562. lev = 2
  1563. call checkexp
  1564. ogun = 'Young Gun'
  1565. ohit = '120'
  1566. obj = 'The Lynch mob'
  1567. obullets = 120
  1568. str = CLS
  1569. call Out
  1570. str = ' '
  1571. call Out
  1572. str = '            '||BLU||'__________________________________________________'Off
  1573. call Out
  1574. str = '           'BluPur'| Level 2 - Rescue your friends from the Lynch Mob |'Off
  1575. call Out
  1576. str = '           'BluPur'|__________________________________________________|'Off
  1577. call Out
  1578. str = ''
  1579. call Out
  1580. str = '     You must rescue your friends, Chavez and Doc, from the Lynch mob in'
  1581. call Out
  1582. str = ' Lincoln town. Rescue them and you will have new partners for the rest of'
  1583. call Out
  1584. str = ' your journey to find Old Mexico.  Good luck!'
  1585. call Out
  1586. str = ''
  1587. call Out
  1588. str = Cya||'Are you ready for this mission? ['||Wht||'Y'||Cya||'/n]'||Off
  1589. call GetKey
  1590. p = upper(hot)
  1591. str = ''
  1592. call Out
  1593. if p = "N" then call main
  1594. signal Level22
  1595. end
  1596.  
  1597. Level22:
  1598. call checklev
  1599. call levelstats
  1600. str = Cya'Command '||BLU||'->'Off
  1601. call GetKey
  1602. q = upper(hot)
  1603. str = ''
  1604. call Out
  1605. str = CLS
  1606. call Out
  1607. if q = "F" then do
  1608. call shoot
  1609. call cshoot
  1610. end
  1611. if q = "H" then call healer
  1612. if q = "Q" then call levelquit
  1613. signal level22
  1614.  
  1615. Sgun:
  1616. if gun = 'Old Pistol' then do
  1617. str = Red'You can''t sell your Old Pistol, it''s too old!'Off
  1618. call Out
  1619. address command "wait 2"
  1620. call store;end
  1621. if gun = 'Pistol' then do
  1622. str = Blu||'I will give you '||Grn||'$500 '||Blu||'for that Pistol. ['||Pur||'Y'||Blu||'/n] >'||Off
  1623. call GetKey
  1624. a = upper(hot)
  1625. str = ''
  1626. call Out
  1627. if a = "N" then call store
  1628. str = Yel'Pistol was sold for 'Grn'$500'||YEL||'.'Off
  1629. call Out
  1630. address command "wait 2"
  1631. gun = 'Old Pistol'
  1632. money = money + 500
  1633. call store;end
  1634. if gun = 'Long Barrel' then do
  1635. str = Blu||'I will give you '||Grn||'$1000 '||Blu||'for that Long Barrel.'
  1636. call Out
  1637. str = BLU'['||Pur'Y'||Blu||'/n]'||Off
  1638. call GetKey
  1639. a = upper(hot)
  1640. str = ''
  1641. call Out
  1642. if a = "N" then call store
  1643. str = Yel||'Long Barrel was sold for '||Grn||'$1000'||Yel||'.'||Off
  1644. call Out
  1645. address command "wait 2"
  1646. gun = 'Old Pistol'
  1647. money = money + 1000
  1648. call store;end
  1649. if gun = 'Shotgun' then do
  1650. str = Blu||'I will give you '||Grn||'$2000 '||Blu||'for that shotgun.'OFF
  1651. call Out
  1652. str = BLU'['||Pur||'Y'||Blu||'/n]'||Off
  1653. call GetKey
  1654. a = upper(hot)
  1655. str = ''
  1656. call Out
  1657. if a = "N" then call store
  1658. str = Yel||'Shotgun was sold for '||Grn||'$2000'||Yel||'.'||Off
  1659. call Out
  1660. address command "wait 2"
  1661. gun = 'Old Pistol'
  1662. money = money + 2000
  1663. call store;end
  1664. if gun = 'Young Gun' then do
  1665. str = Blu||'I will give you '||Grn||'$3000 '||Blu||'for that Young Gun.'OFF
  1666. call Out
  1667. str = BLU'['||Pur||'Y'||Blu||'/n]'||Off
  1668. call GetKey
  1669. a = upper(hot)
  1670. str = ''
  1671. call Out
  1672. if a = "N" then call store
  1673. str = Yel||'Young Gun was sold for '||Grn||'$3000'||Yel||'.'||Off
  1674. call Out
  1675. address command "wait 2"
  1676. gun = 'Old Pistol'
  1677. money = money + 3000
  1678. call store;end
  1679. call store
  1680.  
  1681. Level3:
  1682. lev = 3
  1683. call checkexp
  1684. str = CLS
  1685. call Out
  1686. str = ' '
  1687. call Out
  1688. str = '                   '||BLU||'_______________________________________'Off
  1689. call Out
  1690. str = '                  'BluWht'| Level 3 - Escape from the Lincoln Men |'Off
  1691. call Out
  1692. str = '                  'BluWht'|_______________________________________|'Off
  1693. call Out
  1694. str = ''
  1695. call Out
  1696. str = '     Your mission is to take you and your friends to a safe place. You'
  1697. call Out
  1698. str = ' must travel 80 miles to before you are free. If not, you will lose the'
  1699. call Out
  1700. str = ' mission. Also, make sure your hitpoints and bullets are okay. Good luck!'
  1701. call Out
  1702. str = ''
  1703. call Out
  1704. str = Cya'Are you ready for this mission? ['||PUR||'Y'||CYA||'/n]'Off
  1705. call GetKey
  1706. s = upper(hot)
  1707. str = ''
  1708. call Out
  1709. if s = "N" then call main
  1710. ogun = 'Young Gun'
  1711. obullets = 250
  1712. ohit = 250
  1713. obj = 'The Lincoln Men'
  1714. miles = 0
  1715. signal level33
  1716.  
  1717. Level33:
  1718. if miles = 80 | miles > 80 then do
  1719. str = Blu'You out ran the Lincoln men.  You win!'Off
  1720. call Out
  1721. levw = 1
  1722. call levelsave;end
  1723. call checklev
  1724. str = Blu||'Miles traveled so far '||Cya||': '||Yel||''miles''||Off
  1725. call Out
  1726. address command "wait 2"
  1727. call levelstats
  1728. str = Cya||'Command '||Blu||'->'||Off
  1729. call GetKey
  1730. c = upper(hot)
  1731. str = ''
  1732. call Out
  1733. if c = "F" then do
  1734. call shoot
  1735. call cshoot
  1736. call Out
  1737. str = Blu'80 Miles traveled.'Off
  1738. miles = miles + 4
  1739. end
  1740. if c = "H" then call healer
  1741. if c = "Q" then call levelquit
  1742. signal Level33
  1743.  
  1744. Level4:
  1745. lev = 4
  1746. call checkexp
  1747. str = CLS
  1748. call Out
  1749. str = ' '
  1750. call Out
  1751. str = '                '||CYA||'_____________________________________________'Off
  1752. call Out
  1753. str = '               'CyaWht'| Level 4 - Escape the Lincoln Men''s building |'Off
  1754. call Out
  1755. str = '               'CyaWht'|_____________________________________________|'Off
  1756. call Out
  1757. str = ''
  1758. call Out
  1759. str = '     You were captured by the Lincoln Men. You must try and escape the Lincoln'
  1760. call Out
  1761. str = ' Men''s building. If you do not succeed you will be hanged. Try everything you'
  1762. call Out
  1763. str = ' have to, this is one tough mission!  Good Luck!'
  1764. call Out
  1765. str = ''
  1766. call Out
  1767. str = Cya||'Are you ready for this mission? ['||Blu||'Y'||Cya||'/n]'||Off
  1768. call GetKey
  1769. i = upper(hot)
  1770. str = ''
  1771. call Out
  1772. if i = "N" then call main
  1773. call locat1
  1774.  
  1775. loc1:
  1776. str = Blu'Storage Room'Off
  1777. call Out
  1778. str = Cya'You are on the top floor of a storage room. There is a open shaft above you.'Off
  1779. call Out
  1780. str = Cya'Up is the only direction out.'Off
  1781. call Out
  1782. return
  1783.  
  1784. loc2:
  1785. str = Blu'Center of Roof'Off
  1786. call Out
  1787. str = Cya'You are on the top of the Lincoln Men''s business office. There are exits to'Off
  1788. call Out
  1789. str = Cya'the east and west.'Off
  1790. call Out
  1791. return
  1792.  
  1793. loc3:
  1794. str = Blu'East Roof'Off
  1795. call Out
  1796. str = Cya'You are on the east roof on the Lincoln Men''s building. There are two exits,'Off
  1797. call Out
  1798. str = Cya'down and west.'
  1799. call Out
  1800. return
  1801.  
  1802. loc4:
  1803. str = Blu'West Roof'Off
  1804. call Out
  1805. str = Cya'You are on the west side of the Lincoln Men''s building. East is the only exit.'Off
  1806. call Out
  1807. return
  1808.  
  1809. loc5:
  1810. str = Blu'Road Path'Off
  1811. call Out
  1812. str = Cya'You are out of the building. There is a horse here. Up is the only exit.'Off
  1813. call Out
  1814. str = Cya'There is an exit north, but it''s too far to walk on foot.'Off
  1815. call Out
  1816. return
  1817.  
  1818. locat1:
  1819. call loc1
  1820. str = Blu||'Command '||Yel||'-> ['||Grn||'?'||Blu||' = Help] '||Off
  1821. length = 25
  1822. call Input
  1823. le = upper(typed)
  1824. str = ''
  1825. call Out
  1826. if le = "LOOK" then call locat1
  1827. if le = "?" then call level4help
  1828. if le = "SLIP OUT OF HANDCUFFS" | le = "BOUNCE CHAIR" | le = "SLIP OFF HANDCUFFS" | le = "SLIP OUT" | le = "BREAK OUT" | le = "PULL HANDS OUT" then do
  1829. str = Blu'You successfully slip your hands through the handcuffs.'Off
  1830. call Out
  1831. ha = 1;end
  1832. if le = "Q" then call level4e
  1833. if le = "U" then do
  1834. if ha = 0 then do
  1835. str = Red'You can''t get up!  You''re handcuffed to the chair!'Off
  1836. call Out
  1837. end
  1838. if ha = 1 then do
  1839. str = Blu'You climb up through the ceiling shaft.'Off
  1840. call Out
  1841. call locat2;end
  1842. end
  1843. if le = "N" | le = "Q" | le = "S" | le = "E" | le = "W" then call Out Red'You can''t go that way!'Off
  1844. call Locat1
  1845.  
  1846. Locat2:
  1847. call loc2
  1848. str = Blu'Command '||PUR||'-> ['Wht'?'||BLU||' = Help] 'Off
  1849. length = 5
  1850. call Input
  1851. le = upper(typed)
  1852. if le = "LOOK" then call locat2
  1853. if le = "Q" then call level4e
  1854. if le = "E" then call locat3
  1855. if le = "W" then call locat4
  1856. if le = "?" then call level4Help
  1857. if le = "D" then call locat1
  1858. call Locat2
  1859.  
  1860. Locat3:
  1861. call loc3
  1862. str = Cya'Command 'Wht'-> ['||BLU||'?'||CYA||' = Help] 'Off
  1863. length = 5
  1864. call Input
  1865. le = upper(typed)
  1866. str = ''
  1867. call Out
  1868. if le = "LOOK" then call locat3
  1869. if le = "D" then call locat5
  1870. if le = "?" then call level4help
  1871. if le = "E" | le = "S" | le = "U" | le = "N" then do
  1872. str = Red'You can''t go that way!'Off
  1873. call Out
  1874. end
  1875. if le = "W" then call locat2
  1876. if le = "Q" then call level4e
  1877. call Locat3
  1878.  
  1879. Locat4:
  1880. call loc4
  1881. str = Blu||'Command '||Wht||'-> ['||Yel||'?'||Blu||' = Help] '||Off
  1882. length = 25
  1883. call Input
  1884. le = upper(typed)
  1885. str = ''
  1886. call Out
  1887. if le = "LOOK" then call locat4
  1888. if le = "E" then call locat2
  1889. if le = "Q" then call level4e
  1890. if le = "?" then call level4help
  1891. if le = "W" | le = "S" | le = "N" | le = "U" | le = "D" then do
  1892. str = Red'You can''t go that way!'Off
  1893. call Out
  1894. end
  1895. call locat4
  1896. level4help:
  1897. str = ''
  1898. call Out
  1899. str = Blu'Help Commands'||YEL||':'Off
  1900. call Out
  1901. str = Yel'LOOK '||CYA||'[Look around]'Off
  1902. call Out
  1903. str = Yel'['||BLU||'N'||YEL||'] '||CYA||'[Go North]'Off
  1904. call Out
  1905. str = Yel'['||BLU||'S'||YEL||'] '||CYA||'[Go South]'Off
  1906. call Out
  1907. str = Yel'['||BLU||'E'||YEL||'] '||CYA||'[Go East]'Off
  1908. call Out
  1909. str = Yel'['||BLU||'W'||YEL||'] '||CYA||'[Go West]'Off
  1910. call Out
  1911. str = Yel'['||BLU||'U'||YEL||'] '||CYA||'[Up]'Off
  1912. call Out
  1913. str = Yel'['||BLU||'D'||YEL||'] '||CYA||'[Down]'Off
  1914. call Out
  1915. str = Yel'['||BLU||'Q'||YEL||'] '||CYA||'[Quit and get captured]'Off
  1916. call Out
  1917. str = ''
  1918. call Out
  1919. str = Red'HINT '||BLU||'- '||YEL||'You have small wrists.'Off
  1920. call Out
  1921. return
  1922.  
  1923. Locat5:
  1924. call loc5
  1925. str = Blu||'Command '||Yel||'-> ('||CYA||'?'||Blu||' = Help)'||Off
  1926. length = 25
  1927. call Input
  1928. le = upper(typed)
  1929. str = ''
  1930. call Out
  1931. if le = "LOOK" then call locat3
  1932. if le = "STEAL HORSE" | le = "RIDE HORSE" | le = "GET ON HORSE" | le = "TAKE HORSE" then do
  1933. str = Yel'You successfully escaped the Lincoln Men!  Nice going!'Off
  1934. call Out
  1935. level = 4
  1936. levw = 1;call levelsave
  1937. call main
  1938. end
  1939. if le = "U" then call Locat3
  1940. if le = "Q" then call level4e
  1941. if le = "?" then call level4help
  1942. if le = "W" | le = "S" | le = "N" | le = "E" | le = "D" then do
  1943. str = Red'You can''t go that way!'Off
  1944. call Out
  1945. end
  1946. call Locat5
  1947.  
  1948. Level4e:
  1949. str = Blu||'You have given up and failed the mission!  You lose '||Grn||'$1000'||Blu||'.'||Off
  1950. call Out
  1951. money = money - 1000
  1952. levl = 1
  1953. call levelsave
  1954. end
  1955.  
  1956. Level5:
  1957. lev = 5
  1958. call checkexp
  1959. obj = 'The Murphy Men'
  1960. ogun = 'Young Gun'
  1961. ohit = 300
  1962. obullets = 300
  1963. str = CLS
  1964. call Out
  1965. str = ' '
  1966. call Out
  1967. str = '                    '||CYA||'_____________________________________'Off
  1968. call Out
  1969. str = '                   'CyaBlu'| Level 5 - Finish off the Murphy Men |'Off
  1970. call Out
  1971. str = '                   'CyaBlu'|_____________________________________|'Off
  1972. call Out
  1973. str = ''
  1974. call Out
  1975. str = '     You meet up with the Murphy Men for the last time. You need to defeat'
  1976. call Out
  1977. str = ' these men to continue your mission. These men are strong so be prepared!' 
  1978. call Out
  1979. str = ' Good luck!'
  1980. call Out
  1981. str = ''
  1982. call Out
  1983. str = Grn||'Are you ready for this mission? ['||Blu||'Y'||Grn||'/n]'||Off
  1984. call GetKey
  1985. s = upper(hot)
  1986. str = ''
  1987. call Out
  1988. if s = "N" then call main
  1989. signal level55
  1990.  
  1991. Level55:
  1992. call checklev
  1993. call levelstats
  1994. str = Grn'Command '||YEL||'->'Off
  1995. call GetKey
  1996. a = upper(hot)
  1997. str = ''
  1998. call Out
  1999. if a = "F" then do
  2000. call shoot
  2001. call cshoot
  2002. end
  2003. if a = "H" then call healer
  2004. if a = "Q" then do
  2005. str = Yel'You lose 'Grn'$1000 '||YEL||'for this foolish act.'Off
  2006. call Out
  2007. money = money - 1000
  2008. levl = 1;call levelsave;end
  2009. signal Level55
  2010.  
  2011. Level6:
  2012. lev = 6
  2013. call checkexp
  2014. obj = 'The Two Mexicans'
  2015. ohit = 350
  2016. obullets = 350
  2017. ogun = 'Young Gun'
  2018. str = CLS
  2019. call Out
  2020. str = ' '
  2021. call Out
  2022. str = '             '||CYA||'____________________________________________________'Off
  2023. call Out
  2024. str = '            'CyaPur'| Level 6 - Kill the Two Mexicans blocking the path  |'Off
  2025. call Out
  2026. str = '            'CyaPur'|____________________________________________________|'Off
  2027. call Out
  2028. str = ''
  2029. call Out
  2030. str = '     They are called the Two Mexicans of Mexico. They are the best in'
  2031. call Out
  2032. str = ' Mexico and they don''t like you too much. They start firing at you.  You'
  2033. call Out
  2034. str = ' are forced to battle.'
  2035. call Out
  2036. str = ''
  2037. call Out
  2038. str = Cya||'Are you ready for this mission? ['||Grn||'Y'||Cya||'/n]'||Off
  2039. call GetKey
  2040. d = upper(hot)
  2041. str = ''
  2042. call Out
  2043. if d = "N" then call main
  2044. signal level66
  2045.  
  2046. Level66:
  2047. call checklev
  2048. call levelstats
  2049. str = Blu||'Command '||Pur||'->'||Off
  2050. call GetKey
  2051. f = upper(hot)
  2052. str = ''
  2053. call Out
  2054. if f = "F" then do
  2055. call shoot
  2056. call cshoot
  2057. end
  2058. if f = "H" then call healer
  2059. if f = "Q" then do
  2060. str = Blu'You lose 'Grn'$1000 '||BLU||'for this foolish act.'Off
  2061. call Out
  2062. money = money - 1000
  2063. levl = 1;call levelsave;end
  2064. signal Level66
  2065.  
  2066. Level7:
  2067. lev = 7
  2068. call checkexp
  2069. obj = 'Pat Garret and men'
  2070. ohit = 400
  2071. obullets = 400
  2072. ogun = 'Young Gun'
  2073. str = CLS
  2074. call Out
  2075. str = ' '
  2076. call Out
  2077. str = '                 '||BLU||'____________________________________________'Off
  2078. call Out
  2079. str = '                'BluYel'| Level 7 - You encounter Sheriff Pat Garret |'Off
  2080. call Out
  2081. str = '                'BluYel'|____________________________________________|'Off
  2082. call Out
  2083. str = ''
  2084. call Out
  2085. str = '     Pat Garret has been offered $1000 to hunt you down and kill you. He is' 
  2086. call Out
  2087. str = ' not fooling around. You must scare him off by firing at him. Your party is' 
  2088. call Out
  2089. str = ' here to help you.'
  2090. call Out
  2091. str = ''
  2092. call Out
  2093. str = Yel||'Are you ready for this mission? ['||Blu||'Y'||Yel||'/n]'||Off
  2094. call GetKey
  2095. d = upper(hot)
  2096. str = ''
  2097. call Out
  2098. if d = "N" then call main
  2099. signal level77
  2100.  
  2101. Levelstats:
  2102. str = CLS
  2103. call Out
  2104. str = '(Your hits '||Pur||':'||Off||' '||Cya||''hits''||Off||') (Your bullets '||Pur||':'||Off||' '||Cya||''bullets''||Off||')'
  2105. call Out
  2106. str = '('obj'''s hits '||Yel||':'||Off||' '||Red||''ohit''||Off||') ('obj'''s bullets '||Yel||':'||Off||' '||Red||''obullets''||Off||')'
  2107. call Out
  2108. str = ''||Yel||'['||Blu||'F'||Yel||'] '||Blu||'- '||Cya||'Fire at '||Pur||''obj' '||Blu||' '||Yel||'['||Blu||'H'||Yel||'] '||Blu||'- '||Cya||'Heal yourself '||Blu||' '||Yel||'['||Blu||'Q'||Yel||'] '||Blu||'- '||Cya||'Quit and give up'||Off
  2109. call Out
  2110. return
  2111.  
  2112. Level77:
  2113. call checklev
  2114. call levelstats
  2115. str = Red'Command '||YEL||'->'Off
  2116. call GetKey
  2117. g = upper(hot)
  2118. str = ''
  2119. call Out
  2120. if g = "F" then do
  2121. call shoot
  2122. call fshoot
  2123. call cshoot
  2124. end
  2125. if g = "H" then call healer
  2126. if g = "Q" then call levelquit
  2127. signal Level77
  2128.  
  2129. levelquit:
  2130. if lev = 10 then do
  2131. str = Red'Sorry, you have lost!  Back we go to level 1!'Off
  2132. call Out
  2133. address command "wait 2"
  2134. level = 0;call main;end
  2135. str = Yel'For your cowardly act, you lose 'Grn'$1000'Red'.'Off
  2136. call Out
  2137. money = money - 1000
  2138. levl = 1;call levelsave;end
  2139.  
  2140. fshoot:
  2141. if lev = 7 then do
  2142. str = Cya'Chavez, Doc, Arkansas Dave and Buckshot George fire.'Off
  2143. call Out
  2144. end
  2145. return
  2146.  
  2147. Level8:
  2148. lev = 8
  2149. call checkexp
  2150. ohit = 450
  2151. ogun = 'Young Gun'
  2152. obullets = 450
  2153. obj = 'The Lincoln Man'
  2154. str = CLS
  2155. call Out
  2156. str = ' '
  2157. call Out
  2158. str = '                   'Red'______________________________________'Off
  2159. call Out
  2160. str = '                  'RedYel'| Level 8 - Fight The Mad Lincoln Man  |'Off
  2161. call Out
  2162. str = '                  'RedYel'|______________________________________|'Off
  2163. call Out
  2164. str = ''
  2165. call Out
  2166. str = '     You encounter a Mad Lincoln Man on your way to Old Mexico. You must' 
  2167. call Out
  2168. str = 'fight him to continue on.'
  2169. call Out
  2170. str = ''
  2171. call Out
  2172. str = Cya||'Are you ready for this mission? ['||Wht||'Y'||Cya||'/n]'||Off
  2173. call GetKey
  2174. s = upper(hot)
  2175. str = ''
  2176. call Out
  2177. if s = "N" then call main
  2178. call level88
  2179.  
  2180. Level88:
  2181. call checklev
  2182. call levelstats
  2183. str = Blu'Command '||CYA||'->'Off
  2184. call GetKey
  2185. d = upper(hot)
  2186. str = ''
  2187. call Out
  2188. if d = "F" then do
  2189. call shoot
  2190. call cshoot
  2191. end
  2192. if d = "H" then call healer
  2193. call Level88
  2194.  
  2195. Level9:
  2196. lev = 9
  2197. call checkexp
  2198. obj = 'The Enemies'
  2199. ohit = 800
  2200. obullets = 300
  2201. ogun = 'Young Gun'
  2202. str = CLS
  2203. call Out
  2204. str = ' '
  2205. call Out
  2206. str = '         '||CYA||'___________________________________________________________'Off
  2207. call Out
  2208. str = '        'CyaBlu'| Level 9 - Kill the last of the Lincoln Men and Murphy Men |'Off
  2209. call Out
  2210. str = '        'CyaBlu'|___________________________________________________________|'Off
  2211. call Out
  2212. str = ''
  2213. call Out
  2214. str = '     You are forced to enter a shoot out with the Lincoln Men and Murphy Men.'
  2215. call Out
  2216. str = ' Arkansas Dave fled out of this battle and went to Old Mexico. You are here'
  2217. call Out
  2218. str = ' to fight now, so there''s no stopping.'
  2219. call Out
  2220. str = ''
  2221. call Out
  2222. str = Yel||'Are you ready for this mission? ['||Blu||'Y'||Yel||'/n]'||Off
  2223. call GetKey
  2224. g = upper(hot)
  2225. str = ''
  2226. call Out
  2227. if g = "N" then call main
  2228. call level99
  2229.  
  2230. Level99:
  2231. call checklev
  2232. call levelstats
  2233. str = Blu'Command 'Wht'->'Off
  2234. call GetKey
  2235. w = upper(hot)
  2236. str = ''
  2237. call Out
  2238. if w = "F" then do
  2239. call shoot
  2240. call cshoot
  2241. end
  2242. if w = "H" then call healer
  2243. if w = "Q" then call levelquit
  2244. call Level99
  2245.  
  2246. Level10:
  2247. lev = 10
  2248. call checkexp
  2249. obj = 'Pat Garret'
  2250. ohit = 1000
  2251. obullets = 1000
  2252. ogun = 'Young Gun'
  2253. str = CLS
  2254. call Out
  2255. str = ' '
  2256. call Out
  2257. str = '           '||BLU||'_______________________________________________________'Off
  2258. call Out
  2259. str = '          'BluPur'|* Level 10 - Your last battle with Sheriff Pat Garret *|'Off
  2260. call Out
  2261. str = '          'BluPur'|_______________________________________________________|'Off
  2262. call Out
  2263. str = ''
  2264. call Out
  2265. str = '     Pat Garret finally cought up with you and now he is going to end it all' 
  2266. call Out
  2267. str = ' here. Make sure you''re prepared, he''s tough! If you lose this mission in'  
  2268. call Out
  2269. str = ' anyway, you will be sent back down to level 1. Be smart and good luck!'
  2270. call Out
  2271. str = ''
  2272. call Out
  2273. str = Pur||'Are you ready for this mission? ['||Yel||'Y'||Pur||'/n]'||Off
  2274. call GetKey
  2275. y = upper(hot)
  2276. str = ''
  2277. call Out
  2278. if y = "N" then call main
  2279. call level10!
  2280.  
  2281. Level10!:
  2282. call checklev
  2283. call levelstats
  2284. str = Cya'Command '||PUR||'->'Off
  2285. call GetKey
  2286. g = upper(hot)
  2287. str = ''
  2288. call Out
  2289. if g = "F" then do
  2290. call shoot
  2291. call cshoot
  2292. end
  2293. if g = "H" then call healer
  2294. if g = "Q" then call levelquit
  2295. call Level10!
  2296.  
  2297. Checkexp:
  2298. if lev = 2 then do
  2299. if exp > 100 then return
  2300. if exp < 100 then do
  2301. str = Red'You need at least 100 experience points to complete level 2.'Off
  2302. call Out
  2303. address command "wait 2"
  2304. call main;end
  2305. end
  2306. if lev = 3 then do
  2307. if exp > 200 then return
  2308. if exp < 200 then do
  2309. str = Red'You need at least 200 experience points to complete level 3.'Off
  2310. call Out
  2311. address command "wait 2"
  2312. call main;end
  2313. end
  2314. if lev = 4 then do
  2315. if exp > 300 then return
  2316. if exp < 300 then do
  2317. str = Red'You need at least 300 experience points to complete level 4.'Off
  2318. call Out
  2319. address command "wait 2"
  2320. call main;end
  2321. end
  2322. if lev = 5 then do
  2323. if exp > 400 then return
  2324. if exp < 400 then do
  2325. str = Red'You need at least 400 experience points to complete level 5.'Off
  2326. call Out
  2327. address command "wait 2"
  2328. call main;end
  2329. end
  2330. if lev = 6 then do
  2331. if exp > 500 then return
  2332. if exp < 500 then do
  2333. str = Red'You need at least 500 experience points to complete level 6.'Off
  2334. call Out
  2335. address command "wait 2"
  2336. call main;end
  2337. end
  2338. if lev = 7 then do
  2339. if exp > 600 then return
  2340. if exp < 600 then do
  2341. str = Red'You need at least 600 experience points to complete level 7.'Off
  2342. call Out
  2343. address command "wait 2"
  2344. call main;end
  2345. end
  2346. if lev = 8 then do
  2347. if exp > 700 then return
  2348. if exp < 700 then do
  2349. str = Red'You need atleast 700 experience points to complete level 8.'Off
  2350. call Out
  2351. address command "wait 2"
  2352. call main;end
  2353. end
  2354. if lev = 9 then do
  2355. if exp > 800 then return
  2356. if exp < 800 then do
  2357. str = Red'You need atleast 800 experience points to complete level 9.'Off
  2358. call Out
  2359. address command "wait 2"
  2360. call main;end
  2361. end
  2362. if lev = 10 then do
  2363. if exp > 900 then return
  2364. if exp < 900 then do
  2365. str = Red'You need at least 900 experience points to complete level 10.'Off
  2366. call Out
  2367. address command "wait 2"
  2368. call main;end
  2369. end
  2370. return
  2371.  
  2372. Bye:
  2373. call open(file,'DOORS:YoungGuns/pistolers/'username'',"W")
  2374. call writeln file, gun;call writeln file, bullets;call writeln file, wins
  2375. call writeln file, lost;call writeln file, level;call writeln file, exp
  2376. call writeln file, money;call writeln file, bankmon;call writeln file, hits
  2377. call writeln file, med;call writeln file, alias
  2378. call close(file)
  2379. call ENDIT
  2380.  
  2381. IOERR:
  2382. leine = SIGL
  2383. CODE = RC
  2384. call Bl
  2385. str = "-=* A FATAL I/O error has occured *=-  PLEASE notify the sysop."
  2386. call Out
  2387. str = "Line:" leine
  2388. call Out
  2389. call Bl
  2390. str = "PLEASE write down the TYPE of ERROR and the LINE # and"
  2391. call Out
  2392. str = "leave the SYSOP a message so he may get it corrected."
  2393. call Out
  2394. call Returnc
  2395. if exists(path"ERRORLOG") then do
  2396.  call open(path"errorlog", "A")
  2397. end
  2398.  else do
  2399.  call open(path"errorlog", "W")
  2400. end
  2401.   erstring3="*I/O Error*  Line: "LeiNE
  2402. signal ENDIT
  2403.  
  2404. ERROR:
  2405. leine = SIGL
  2406. CODE = RC
  2407. call Bl
  2408. str = "-=* A FATAL General Failure has occured *=-  PLEASE notify the sysop."
  2409. call Out
  2410. str = "Line:" SIGL "   Severity:" code
  2411. call Out
  2412. call Bl
  2413. str = "PLEASE write down the TYPE of ERROR and the LINE # and"
  2414. call Out
  2415. str = "leave the SYSOP a message so he may get it corrected."
  2416. call Out
  2417. call Returnc
  2418. if exists(path"ERRORLOG") then do
  2419.  call open(path"errorlog", "A")
  2420. end
  2421. else do
  2422. call open(path"errorlog", "W")
  2423. end
  2424.  erstring3="*General Failure Error*  Line: "LeINE" ERRORCODE: "CODE
  2425. signal ENDIT
  2426.  
  2427. SYNTAX:
  2428. leine = SIGL
  2429. CODE = RC
  2430. call Bl
  2431. str = "-=* A FATAL Syntax Error has occured *=-  PLEASE notify the sysop."
  2432. call Out
  2433. str = " Line:"leine"   Error Code:" code
  2434. call Out
  2435. call Bl
  2436. str = "PLEASE write down the TYPE of ERROR and the LINE # and"
  2437. call Out
  2438. str = "leave the SYSOP a message so he may get it corrected."
  2439. call Out
  2440. call Returnc
  2441. if exists(path"ERRORLOG") then do
  2442.  call open(path"errorlog", "A")
  2443. end
  2444. else do
  2445. call open(path"errorlog", "W")
  2446. end
  2447.   erstring3 = "*Syntax Error*  Line: "LeINE" ERRORCODE: "CODE
  2448. signal ENDIT 
  2449.  
  2450. GETKEY:
  2451. call hotkey dn,ln,str
  2452. hot=result
  2453. call checkcarrier
  2454. return
  2455.  
  2456. INPUT:
  2457. call Prompt dn,ln,str,length
  2458. typed=result
  2459. call checkcarrier
  2460. return
  2461.  
  2462. OUT:
  2463. call message dn,ln,str,1
  2464. return
  2465.  
  2466. BL:
  2467. str = " "
  2468. call out
  2469. return
  2470.  
  2471. CHECKCARRIER:
  2472. call cdetect dn,ln
  2473. if upper(result) = "NO CARRIER!" then signal Endit
  2474. return
  2475.  
  2476. INUSEENDIT:
  2477. call lf2
  2478. str = "Returning to" BBSName " ..."
  2479. call Out
  2480. signal GetOut
  2481.  
  2482. DELETEINUSE:
  2483. if exists(Mainpath"INUSE.txt") then do        
  2484. address command "delete "mainpath"INUSE.txt QUIET"
  2485. end
  2486. return
  2487.  
  2488. ENDIT:
  2489. call deleteinuse
  2490. str = CLS
  2491. call Out
  2492. signal GetOut
  2493.  
  2494. RETURNC:
  2495. call Bl
  2496. str = CYA "Press any key to continue...."
  2497. call GetKey
  2498. call Bl
  2499. call ENDIT
  2500.  
  2501. GETOUT:
  2502. call Bl
  2503. str = CYA "You've been using "doorName" by "author"."
  2504. call Out
  2505. call Bl
  2506. str = CYA "Thank you," username ", please press [RETURN] or [ENTER]."
  2507. call GetKey
  2508. call Bl
  2509. call Exit_Door DoorName,LineNumber
  2510. Exit 0
  2511.